package quartz;

import org.quartz.Job;
import org.quartz.JobExecutionContext;
import org.quartz.JobExecutionException;

import java.text.SimpleDateFormat;
import java.util.Date;

/**
 * Created by Zhou_Bing on 2019/4/16.
 */
public class MyJob implements Job{
    @Override
    public void execute(JobExecutionContext context)
            throws JobExecutionException {
        System.out.println(context.getMergedJobDataMap().get("task")+new SimpleDateFormat("yyyy-MM-dd HH:mm:ss ").format(new Date()));

    }

}
